<template>
	<div class="goodNav">
		<div class="btns">
			<!-- 默认插槽 -->
			<slot></slot>
		</div>
		<div class="actionBtn">
			<div class="addCart" @click="$emit('addCart-click',$event)">加入购物车</div>
			<div class="buy" @click="$emit('buy-click',$event)">立即购买</div>
		</div>
	</div>
</template>

<script>

</script>

<style lang="scss" scoped="scoped">
	.goodNav {
		position: fixed;
		left: 0;
		bottom: 0;
		right: 0;
		box-shadow: 0 -2px 3px rgba(180, 180, 180, .4);
		height: .88rem;
		display: flex;
		text-align: center;
		align-items: center;
		font-size: .2rem;

		.btns {
			flex: 1;
			display: flex;
		}

		.actionBtn {
			width: 55%;
			display: flex;
			color: #fff;
			padding: 0 .2rem;

		}

		.addCart,
		.buy {
			height: .6rem;
			padding: 0 .4rem;
			line-height: .6rem;
			width: 50%;
		}

		.addCart {
			border-radius: .6rem 0 0 .6rem;
			background-color: #ffaa00;

		}

		.buy {
			border-radius: 0 .6rem .6rem 0;
			background-color: #f30;

		}
	}
</style>
